package com.zx.mes.test.hyl.model.builder.impl;

import com.zx.mes.test.hyl.model.builder.*;

/**
 * 定义n个生成器实现类  实现接口IBuilder
 * @author hyl
 * @date 2018-3-28
 */
public class BuildProduct implements IBuilder{

    Product p = new Product();

    public void createEntity() {
        p.setEntity(new Entity());
  }

    public void createEntity2() {
        p.setEntity2(new Entity2());
    }

    public void createEntity3() {
        p.setEntity3(new Entity3());
    }

    public Product composite() {
        return p;
    }

    public Product create() {
        return composite();
    }
}
